Skip to content

Conversation

@okvidhi
Copy link
Contributor

@okvidhi okvidhi commented Jan 9, 2026

This PR introduces support for the google_dataplex_data_asset resource in the google-beta provider.
This implementation allows for the declarative management of data assets within a Data Product, enabling publishers to curate and share cloud resources like BigQuery datasets.

Key features

  • Hierarchical Resource Linkage: Established the parent-child relationship where the Data Asset is managed under a specific Data Product .
  • LRO Polling: Integrated asynchronous polling to ensure Terraform accurately tracks background asset creation and updates.
  • Access Group Configuration: Support for mapping access groups to specific IAM roles on the underlying cloud resource

Note
Stacked PR: This PR is built on top of the changes in the dataplex-data-products branch and is dependent on those changes being merged first.

`google_dataplex_data_asset`

@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jan 9, 2026
@github-actions github-actions bot requested a review from rileykarson January 9, 2026 06:35
@github-actions
Copy link

github-actions bot commented Jan 9, 2026

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

Googlers: For automatic test runs see go/terraform-auto-test-runs.

@rileykarson, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@github-actions
Copy link

@rileykarson This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@github-actions
Copy link

@GoogleCloudPlatform/terraform-team @rileykarson This PR has been waiting for review for 1 week. Please take a look! Use the label disable-review-reminders to disable these notifications.

@modular-magician modular-magician added service/dataplex and removed awaiting-approval Pull requests that need reviewer's approval to run presubmit tests labels Jan 15, 2026
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 2 files changed, 483 insertions(+))
google-beta provider: Diff ( 10 files changed, 2685 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 2 files changed, 429 insertions(+))

Multiple resources added

This PR adds multiple new resources: google_dataplex_data_asset, google_dataplex_data_product. This makes review significantly more difficult. Please split it into multiple PRs, one per resource.
An override-multiple-resources label can be added to allow merging.

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 77
Passed tests: 73
Skipped tests: 0
Affected tests: 4

Click here to see the affected service packages
  • dataplex

Action taken

Found 4 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccDataplexDataAsset_dataplexDataAssetBasicExample
  • TestAccDataplexDataAsset_dataplexDataAssetFullExample
  • TestAccDataplexDataProduct_dataplexDataProductBasicExample
  • TestAccDataplexDataProduct_dataplexDataProductFullExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccDataplexDataAsset_dataplexDataAssetBasicExample [Debug log]
TestAccDataplexDataAsset_dataplexDataAssetFullExample [Debug log]
TestAccDataplexDataProduct_dataplexDataProductBasicExample [Debug log]
TestAccDataplexDataProduct_dataplexDataProductFullExample [Debug log]

🟢 No issues found for passed tests after REPLAYING rerun.


🟢 All tests passed!

View the build log or the debug log for each test

data_product_id = "{{index $.Vars "data_product_id"}}"
display_name = "terraform data product"

owner_emails = ["[email protected]"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
owner_emails = ["terraform-test@google.com"]
owner_emails = ["gterraformtestuser@gmail.com"]

# UTF-8 verification
description = "Updated with emojis 🚀 and brackets {test}"

owner_emails = ["[email protected]"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
owner_emails = ["terraform-test@google.com"]
owner_emails = ["gterraformtestuser@gmail.com"]

# - '{{data_product_id}}'
import_format:
- 'projects/{{project}}/locations/{{location}}/dataProducts/{{data_product_id}}'
- '{{data_product_id}}'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- '{{data_product_id}}'

location always needs to be provided, I think?

Comment on lines 69 to 70
api_name: 'name'
custom_flatten: 'templates/terraform/custom_flatten/name_from_self_link.tmpl'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
api_name: 'name'
custom_flatten: 'templates/terraform/custom_flatten/name_from_self_link.tmpl'

These can be removed due to url_param_only: true

id_format: 'projects/{{project}}/locations/{{location}}/dataProducts/{{data_product_id}}/dataAssets/{{data_asset_id}}'
import_format:
- 'projects/{{project}}/locations/{{location}}/dataProducts/{{data_product_id}}/dataAssets/{{data_asset_id}}'
- '{{data_product_id}}/{{data_asset_id}}'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- '{{data_product_id}}/{{data_asset_id}}'

Same reasons as below

Comment on lines +56 to +57
api_name: 'name'
custom_flatten: 'templates/terraform/custom_flatten/name_from_self_link.tmpl'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
api_name: 'name'
custom_flatten: 'templates/terraform/custom_flatten/name_from_self_link.tmpl'

Same reasons as below

data_asset_id = "{{index $.Vars "data_asset_id"}}"
resource = "//bigquery.googleapis.com/projects/${google_bigquery_dataset.example.project}/datasets/${google_bigquery_dataset.example.dataset_id}"

# NOTE: access_group_configs is omitted to bypass backend group validation
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you elaborate on why this is needed? Internally would be fine.

@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jan 18, 2026
@github-actions github-actions bot requested a review from rileykarson January 18, 2026 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-approval Pull requests that need reviewer's approval to run presubmit tests service/dataplex

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants